<%@ page language="java" contentType="text/html; charset=utf-8" pageEncoding="utf-8" %>
<%@ include file="../common/taglibs.jsp" %>
<!--_meta 作为公共模版分离出去-->
<!DOCTYPE HTML>
<html>
<head>
    <meta charset="utf-8">
    <meta name="renderer" content="webkit|ie-comp|ie-stand">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1.0,maximum-scale=1.0,user-scalable=no" />
    <meta http-equiv="Cache-Control" content="no-siteapp" />
    <LINK rel="Bookmark" href="/favicon.ico" >
    <LINK rel="Shortcut Icon" href="/favicon.ico" />
    <!--[if lt IE 9]>
    <script type="text/javascript" src="lib/html5.js"></script>
    <script type="text/javascript" src="lib/respond.min.js"></script>
    <script type="text/javascript" src="lib/PIE_IE678.js"></script>
    <![endif]-->
    <link rel="stylesheet" type="text/css" href="static/h-ui/css/H-ui.min.css" />
    <link rel="stylesheet" type="text/css" href="static/h-ui.admin/css/H-ui.admin.css" />
    <link rel="stylesheet" type="text/css" href="lib/Hui-iconfont/1.0.7/iconfont.css" />
    <link rel="stylesheet" type="text/css" href="lib/icheck/icheck.css" />
    <link rel="stylesheet" type="text/css" href="static/h-ui.admin/skin/default/skin.css" id="skin" />
    <link rel="stylesheet" type="text/css" href="static/h-ui.admin/css/style.css" />
    <!--[if IE 6]>
    <script type="text/javascript" src="lib/DD_belatedPNG_0.0.8a-min.js" ></script>
    <script>DD_belatedPNG.fix('*');</script>
    <![endif]-->
    <!--/meta 作为公共模版分离出去-->

    <title>域管理-域基本信息</title>
</head>
<body>
<article class="page-container">
    <form class="form form-horizontal" id="form-admin-add" action="domainSave.htmlx">
        <input type="hidden" name="ext_store_count" value="0">
        <input type="hidden" name ="html" id="html-3"  value="Y"  >
        <input type="hidden" name ="timer" id="timer-3"  value="Y" >
        <input type="hidden" name ="time" id="time"  value="${not empty domainInfoExt.time?domainInfoExt.time:1}"  >
        <input type="hidden" name ="max_send_count" id="max_send_count"  value="${not empty domainInfoExt.max_send_count?domainInfoExt.max_send_count:100}" >
        <input type="hidden" name ="business_directory"  id="cbusiness_directory-3"  value="Y" >
        <input type="hidden" name ="net_disk" id="net_disk-2"  value="Y"  >
        <input type="hidden" class="input-text" value="${domainInfoExt.id}" placeholder="" id="id" name="id">
        <input type="hidden" class="input-text" value="${domainInfoExt.domain}" placeholder="" id="domain" name="domain">
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>域名：</label>
            <div class="formControls col-xs-4 col-sm-3">
                ${domainInfoExt.domain}
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>企业名称：</label>
            <div class="formControls col-xs-4 col-sm-3">
                <input type="text" class="input-text" value="${domainInfoExt.company}" placeholder="" id="company" name="company">
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>类型：</label>
            <div class="formControls col-xs-8 col-sm-9 skin-minimal">
                <div class="radio-box">
                    <input name="type" type="radio" id="type-1" value="企业" <c:if test="${domainInfoExt.type eq '企业'}">checked</c:if>>
                    <label for="type-1">企业</label>
                </div>
                <div class="radio-box">
                    <input type="radio" id="type-2" name="type" value="ICP" <c:if test="${domainInfoExt.type eq 'ICP'}">checked</c:if>>
                    <label for="type-2">ICP</label>
                </div>
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>最大域用户数：</label>
            <div class="formControls col-xs-4 col-sm-3">
                <input type="text" class="input-text" value="${not empty domainInfoExt.max_user_count?domainInfoExt.max_user_count:0}" placeholder="" id="max_user_count" name="max_user_count">
            </div>
            <div class="col-xs-2 col-sm-1">
                个
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>限定邮箱空间总容量：</label>
            <div class="formControls col-xs-4 col-sm-3">
                <input type="text" class="input-text" value="${not empty domainInfoExt.max_store_count?domainInfoExt.max_store_count:0}" placeholder="" id="max_store_count" name="max_store_count">
            </div>
            <div class="col-xs-2 col-sm-1">
                MB
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>限定网盘总容量：</label>
            <div class="formControls col-xs-4 col-sm-3">
                <input type="text" class="input-text" value="${not empty domainInfoExt.disk_store_count?domainInfoExt.disk_store_count:0}" placeholder="" id="disk_store_count" name="disk_store_count">
            </div>
            <div class="col-xs-2 col-sm-1">
                MB
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>超大附件限制大小：</label>
            <div class="formControls col-xs-4 col-sm-3">
                <input type="text" class="input-text" value="${not empty domainInfoExt.sup_attchment_size?domainInfoExt.sup_attchment_size:1024}" placeholder="" id="sup_attchment_size" name="sup_attchment_size">
            </div>
            <div class="col-xs-2 col-sm-1">
                MB
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>用户邮箱默认容量：</label>
            <div class="formControls col-xs-4 col-sm-3">
                <input type="text" class="input-text" value="${not empty domainInfoExt.user_default_size?domainInfoExt.user_default_size:200}" placeholder="" id="user_default_size" name="user_default_size">
            </div>
            <div class="col-xs-2 col-sm-1">
                MB
            </div>
        </div>
        <div class="row cl">
            <label class="form-label col-xs-4 col-sm-3"><span class="c-red">*</span>网络硬盘默认容量：</label>
            <div class="formControls col-xs-4 col-sm-3">
                <input type="text" class="input-text" value="${not empty domainInfoExt.user_disk_default_size?domainInfoExt.user_disk_default_size:100}" placeholder="" id="user_disk_default_size" name="user_disk_default_size">
            </div>
            <div class="col-xs-2 col-sm-1">
                MB
            </div>
        </div>

        <input type="hidden" name ="msg" id="msg-1" value="Y" >
        <%--<div class="row cl">--%>
            <%--<label class="form-label col-xs-4 col-sm-3">短信通知：</label>--%>
            <%--<div class="formControls col-xs-8 col-sm-9 skin-minimal">--%>
                <%--<div class="check-box ">--%>
                    <%--<input type="checkbox" name ="msg" id="msg-1" value="Y" <c:if test="${domainInfoExt.msg eq 'Y'}">checked</c:if> >--%>
                    <%--<label for="msg-1">&nbsp;</label>--%>
                <%--</div>--%>
            <%--</div>--%>
        <%--</div>--%>


        <div class="row cl">
            <div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
                <input class="btn btn-primary radius" type="submit" value="&nbsp;&nbsp;提交&nbsp;&nbsp;">
            </div>
        </div>

        <div class="row cl">
            <div class="col-xs-8 col-sm-9 col-xs-offset-4 col-sm-offset-3">
                <span style="font-size: 10px;color:indianred">注:容量和数量如果设置位0则表示不进行限制</span>
            </div>
        </div>
    </form>
</article>

<!--_footer 作为公共模版分离出去-->
<script type="text/javascript" src="http://lib.h-ui.net/jquery/1.9.1/jquery.min.js"></script>
<script type="text/javascript" src="http://lib.h-ui.net/layer/2.1/layer.js"></script>
<script type="text/javascript" src="http://lib.h-ui.net/icheck/jquery.icheck.min.js"></script>
<script type="text/javascript" src="http://lib.h-ui.net/jquery.validation/1.14.0/jquery.validate.min.js"></script>
<script type="text/javascript" src="http://lib.h-ui.net/jquery.validation/1.14.0/validate-methods.js"></script>
<script type="text/javascript" src="http://lib.h-ui.net/jquery.validation/1.14.0/messages_zh.min.js"></script>
<script type="text/javascript" src="static/h-ui/js/H-ui.js"></script>
<script type="text/javascript" src="static/h-ui.admin/js/H-ui.admin.js"></script>
<!--/_footer /作为公共模版分离出去-->

<!--请在下方写此页面业务相关的脚本-->
<script type="text/javascript">
    $(function(){
        $('.skin-minimal input').iCheck({
            checkboxClass: 'icheckbox-blue',
            radioClass: 'iradio-blue',
            increaseArea: '20%'
        });

        $("#form-admin-add").validate({
            rules:{
                domain:{
                    required:true,
                    minlength:4,
                    maxlength:16
                },
                company:{
                    required:true,
                },
                type:{
                    required:true,
                },
            },
            onkeyup:false,
            focusCleanup:true,
            success:"valid",
            submitHandler:function(form){
                $.ajax({
                    url: "domainSave.htmlx",
                    type:"POST",
                    data:$(form).serializeArray(),
                    success: function(data){
                        $('.btn-refresh').click();
                        location.reload();
                        layer.msg('保存成功!',{icon: 1,time:3000});
                    },
                    error: function(data){
                        layer.msg('操作失败!请联系系统管理员!',{icon: 5,time:1000});
                    }
                })
//             $(form).ajaxSubmit();
//         	 var index = parent.layer.getFrameIndex(window.name);
//              parent.$('.btn-refresh').click();
//              parent.layer.close(index);
            }
        });
    });
</script>
<!--/请在上方写此页面业务相关的脚本-->
</body>
</html>